package com.example.qxfw.qxxx.service.impl;

import com.example.qxfw.common.entity.yj.WarnSignalInfo;
import com.example.qxfw.qxxx.mapper.WarnSignalInfoMapper;
import com.example.qxfw.qxxx.service.WarnSignalInfoService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.sql.Timestamp;
import java.util.List;

@Service
public class WarnSignalInfoServiceImpl implements WarnSignalInfoService {

    @Autowired
    private WarnSignalInfoMapper warnSignalInfoMapper;

    @Override
    public List<WarnSignalInfo> getList(String stationName,String pdtStart,String pdtEnd) {
        return warnSignalInfoMapper.selectList(stationName,Timestamp.valueOf(pdtStart),Timestamp.valueOf(pdtEnd));
    }

    @Override
    public List<String> getArea(String stationName, String time) {
        return warnSignalInfoMapper.selectArea(stationName, Timestamp.valueOf(time));
    }

    @Override
    public List<String> getCity() {
        return warnSignalInfoMapper.selectCity();
    }
}
